<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html>
<html>
<head>
<base href="<%=basePath%>">
<%@include file="./headMeta.jsp" %>
   </head>
<body class="bg-black">
    <div class="form-box" id="login-box">
        <div class="header">登陆Pos系统</div>
        <form action="login.action" method="post" id="loginForm">
            <p style="background:#eaeaec;text-align:center;margin:0;padding-top:10px;color:#333;line-height:14px;margin-bottom:-20px;">${tip}</p>
            <div class="body bg-gray">
                <div class="form-group">
                    <input type="text" name="id" class="form-control  validate[require,plus&0,integer]" placeholder="账号"  autocomplete="off" data-title="账号" />
                </div>
                <div class="form-group">
                    <input type="password" name="password" class="form-control validate[require]" placeholder="密码" autocomplete="off" data-title="密码" />
                </div>
                <div class="form-group">
                    <input type="checkbox" name="remember_me"/>
                    记住我
                </div>
            </div>
            <div class="footer">
                <button type="submit" class="btn btn-primary btn-block">登陆</button>
            </div>
        </form>
    </div>

    <%@include file="./javascript.jsp" %>
     <!-- 校验 -->
<script src="resource/js/validate.js" type="text/javascript"></script>
<script>
		validate.initValidate("loginForm");
		
		$("#loginForm").submit(function(){
			if(validate.validate("loginForm") == false){
				alert(validate.error);
				return false;
			}
		});
		
	</script>

</body>
